// es6: static  静态方法，挂载在class上面的
// 静态方法内部this不会指向某一实例对象而是 指向当前类型
class Person {
    constructor(name) {
        this.name = name
    }
    say() {
        console.log(`hi,this is ${this.name}`);
    }
    static create(name) {
        return new Person(name)
    }
}

let foo = Person.create('tome');
foo.say();